﻿<?php
include 'config.php';
/* session_start();
$lifeTime = 10*24 * 3600;  // 保存一天
session_set_cookie_params($lifeTime); */

$sql = "select * from puhuiwww.shopwwi_article where ac_id = '1'and article_position = '2' order by article_id ";
$query = mysql_query($sql);
while ($rs = mysql_fetch_array($query)){
	$arr[] =$rs;
}

$str= '';
//print_r($arr);
//session_unset($_SESSION['views']);
if(!empty($arr)){
	foreach ($arr as $a=>$b){
	
		$str.='<li> <a style="color:#111;" href=gonggao.php?gonggao_id='.$b['article_id'].'>'.$b['article_title'] .'('.date('Y-m-d',$b['article_time']).')</a></li>';
	
	}
	if(count($arr)<2){
		echo $str;
	}
	else{
		for($i=0;$i<=30;$i++){
			echo $str;
		}
	} 
}
?>
